<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

class CreateQaecmsMenusTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('qaecms_menus', function (Blueprint $table) {
            $table->increments('id')->comment('菜单id');
            $table->integer('pid')->comment('菜单父级ID');
            $table->string('title')->comment('菜单名称');
            $table->string('href')->comment('菜单路由名称');
            $table->string('icon')->comment('菜单图标');
            $table->string('target')->comment('target')->default('_self');
            $table->tinyInteger('status')->comment('状态')->default(0);
            $table->integer('sort')->comment('菜单排序,值越大 排序越向前');
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('qaecms_menus');
    }
}
